Integrand size = 33, antiderivative size = 295 \[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=-\frac {2 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sqrt {\cos (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right ) \sqrt {\sec (c+d x)}}{5 d}+\frac {2 \left (21 a^3 A+21 a A b^2+21 a^2 b B+5 b^3 B\right ) \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {\sec (c+d x)}}{21 d}+\frac {2 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {2 b \left (21 a A b+18 a^2 B+5 b^2 B\right ) \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{21 d}+\frac {2 b^2 (7 A b+11 a B) \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{35 d}+\frac {2 b B \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{7 d} \]
[Out]
Time = 0.60 (sec) , antiderivative size = 295, normalized size of antiderivative = 1.00, number of steps used = 9, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.242, Rules used = {4111, 4161, 4132, 3853, 3856, 2719, 4131, 2720} \[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\frac {2 b \left (18 a^2 B+21 a A b+5 b^2 B\right ) \sin (c+d x) \sec ^{\frac {3}{2}}(c+d x)}{21 d}+\frac {2 \left (5 a^3 B+15 a^2 A b+9 a b^2 B+3 A b^3\right ) \sin (c+d x) \sqrt {\sec (c+d x)}}{5 d}+\frac {2 \left (21 a^3 A+21 a^2 b B+21 a A b^2+5 b^3 B\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )}{21 d}-\frac {2 \left (5 a^3 B+15 a^2 A b+9 a b^2 B+3 A b^3\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{5 d}+\frac {2 b^2 (11 a B+7 A b) \sin (c+d x) \sec ^{\frac {5}{2}}(c+d x)}{35 d}+\frac {2 b B \sin (c+d x) \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2}{7 d} \]
[In]
[Out]
Rule 2719
Rule 2720
Rule 3853
Rule 3856
Rule 4111
Rule 4131
Rule 4132
Rule 4161
Rubi steps \begin{align*} \text {integral}& = \frac {2 b B \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{7 d}+\frac {2}{7} \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x)) \left (\frac {1}{2} a (7 a A+b B)+\frac {1}{2} \left (5 b^2 B+7 a (2 A b+a B)\right ) \sec (c+d x)+\frac {1}{2} b (7 A b+11 a B) \sec ^2(c+d x)\right ) \, dx \\ & = \frac {2 b^2 (7 A b+11 a B) \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{35 d}+\frac {2 b B \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{7 d}+\frac {4}{35} \int \sqrt {\sec (c+d x)} \left (\frac {5}{4} a^2 (7 a A+b B)+\frac {7}{4} \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sec (c+d x)+\frac {5}{4} b \left (21 a A b+18 a^2 B+5 b^2 B\right ) \sec ^2(c+d x)\right ) \, dx \\ & = \frac {2 b^2 (7 A b+11 a B) \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{35 d}+\frac {2 b B \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{7 d}+\frac {4}{35} \int \sqrt {\sec (c+d x)} \left (\frac {5}{4} a^2 (7 a A+b B)+\frac {5}{4} b \left (21 a A b+18 a^2 B+5 b^2 B\right ) \sec ^2(c+d x)\right ) \, dx+\frac {1}{5} \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \int \sec ^{\frac {3}{2}}(c+d x) \, dx \\ & = \frac {2 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {2 b \left (21 a A b+18 a^2 B+5 b^2 B\right ) \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{21 d}+\frac {2 b^2 (7 A b+11 a B) \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{35 d}+\frac {2 b B \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{7 d}+\frac {1}{5} \left (-15 a^2 A b-3 A b^3-5 a^3 B-9 a b^2 B\right ) \int \frac {1}{\sqrt {\sec (c+d x)}} \, dx+\frac {1}{21} \left (21 a^3 A+21 a A b^2+21 a^2 b B+5 b^3 B\right ) \int \sqrt {\sec (c+d x)} \, dx \\ & = \frac {2 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {2 b \left (21 a A b+18 a^2 B+5 b^2 B\right ) \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{21 d}+\frac {2 b^2 (7 A b+11 a B) \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{35 d}+\frac {2 b B \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{7 d}+\frac {1}{5} \left (\left (-15 a^2 A b-3 A b^3-5 a^3 B-9 a b^2 B\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \sqrt {\cos (c+d x)} \, dx+\frac {1}{21} \left (\left (21 a^3 A+21 a A b^2+21 a^2 b B+5 b^3 B\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {1}{\sqrt {\cos (c+d x)}} \, dx \\ & = -\frac {2 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sqrt {\cos (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right ) \sqrt {\sec (c+d x)}}{5 d}+\frac {2 \left (21 a^3 A+21 a A b^2+21 a^2 b B+5 b^3 B\right ) \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {\sec (c+d x)}}{21 d}+\frac {2 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {2 b \left (21 a A b+18 a^2 B+5 b^2 B\right ) \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{21 d}+\frac {2 b^2 (7 A b+11 a B) \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{35 d}+\frac {2 b B \sec ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{7 d} \\ \end{align*}
Time = 5.51 (sec) , antiderivative size = 225, normalized size of antiderivative = 0.76 \[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\frac {2 \sqrt {\sec (c+d x)} \left (-21 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sqrt {\cos (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right )+5 \left (21 a^3 A+21 a A b^2+21 a^2 b B+5 b^3 B\right ) \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )+21 \left (15 a^2 A b+3 A b^3+5 a^3 B+9 a b^2 B\right ) \sin (c+d x)+5 b \left (21 a A b+21 a^2 B+5 b^2 B\right ) \tan (c+d x)+21 b^2 (A b+3 a B) \sec (c+d x) \tan (c+d x)+15 b^3 B \sec ^2(c+d x) \tan (c+d x)\right )}{105 d} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. \(916\) vs. \(2(319)=638\).
Time = 52.70 (sec) , antiderivative size = 917, normalized size of antiderivative = 3.11
method | result | size |
default | \(\text {Expression too large to display}\) | \(917\) |
parts | \(\text {Expression too large to display}\) | \(1175\) |
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 0.13 (sec) , antiderivative size = 364, normalized size of antiderivative = 1.23 \[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=-\frac {5 \, \sqrt {2} {\left (21 i \, A a^{3} + 21 i \, B a^{2} b + 21 i \, A a b^{2} + 5 i \, B b^{3}\right )} \cos \left (d x + c\right )^{3} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right ) + 5 \, \sqrt {2} {\left (-21 i \, A a^{3} - 21 i \, B a^{2} b - 21 i \, A a b^{2} - 5 i \, B b^{3}\right )} \cos \left (d x + c\right )^{3} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right ) + 21 \, \sqrt {2} {\left (5 i \, B a^{3} + 15 i \, A a^{2} b + 9 i \, B a b^{2} + 3 i \, A b^{3}\right )} \cos \left (d x + c\right )^{3} {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right )\right ) + 21 \, \sqrt {2} {\left (-5 i \, B a^{3} - 15 i \, A a^{2} b - 9 i \, B a b^{2} - 3 i \, A b^{3}\right )} \cos \left (d x + c\right )^{3} {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right )\right ) - \frac {2 \, {\left (15 \, B b^{3} + 21 \, {\left (5 \, B a^{3} + 15 \, A a^{2} b + 9 \, B a b^{2} + 3 \, A b^{3}\right )} \cos \left (d x + c\right )^{3} + 5 \, {\left (21 \, B a^{2} b + 21 \, A a b^{2} + 5 \, B b^{3}\right )} \cos \left (d x + c\right )^{2} + 21 \, {\left (3 \, B a b^{2} + A b^{3}\right )} \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{\sqrt {\cos \left (d x + c\right )}}}{105 \, d \cos \left (d x + c\right )^{3}} \]
[In]
[Out]
Timed out. \[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\text {Timed out} \]
[In]
[Out]
\[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int { {\left (B \sec \left (d x + c\right ) + A\right )} {\left (b \sec \left (d x + c\right ) + a\right )}^{3} \sqrt {\sec \left (d x + c\right )} \,d x } \]
[In]
[Out]
\[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int { {\left (B \sec \left (d x + c\right ) + A\right )} {\left (b \sec \left (d x + c\right ) + a\right )}^{3} \sqrt {\sec \left (d x + c\right )} \,d x } \]
[In]
[Out]
Timed out. \[ \int \sqrt {\sec (c+d x)} (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int \left (A+\frac {B}{\cos \left (c+d\,x\right )}\right )\,{\left (a+\frac {b}{\cos \left (c+d\,x\right )}\right )}^3\,\sqrt {\frac {1}{\cos \left (c+d\,x\right )}} \,d x \]
[In]
[Out]